﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.Domain.Repositories;

namespace PHMEE
{
    public interface ISysParaRepository : IRepository<SysPara, Guid>
    {
        /// <summary>
        /// 更新数采器状态
        /// </summary>
        /// <param name="sn">采集器编码</param>
        /// <param name="isOnline">是否在线</param>
        /// <returns></returns>
        Task UpdataOnlineStatueAsync(string sn, bool isOnline);
        /// <summary>
        /// 获取数采器在线数量
        /// </summary>
        /// <returns></returns>
        Task<long> GetOnlineCountAsync();
        /// <summary>
        /// 设置下发参数时间
        /// </summary>
        /// <param name="sn">采集器编码</param>
        /// <returns></returns>
        Task SetParaTimeAsync(string sn);
        /// <summary>
        /// 获取所有采集站编码 (CollectCode)
        /// </summary>
        /// <returns></returns>
        Task<List<string>> GetAllCollectCodesAsync();
        /// <summary>
        /// 根据采集器编码获取 SysPara
        /// </summary>
        /// <param name="collectorCode">采集器编码</param>
        /// <returns></returns>
        Task<SysPara> GetSysParaByCollectorCodeAsync(string collectorCode);
    }
}
